use "$input/yu_ash_ready", clear


* use data after 1965
keep if year >= 1965
eststo clear

eststo: reghdfe cites_pos_m_log   polar_start if rule_NP, absorb(stateyear) cluster(state year)
estimates store model12

eststo: reghdfe cites_pos_m_log   polar_start if rule_P, absorb(stateyear) cluster(state year)
estimates store model11

eststo: reghdfe cites_pos_m_log   polar_start if rule_U, absorb(stateyear) cluster(state year)
estimates store model13

eststo: reghdfe cites_pos_m_log   polar_start if rule_G, absorb(stateyear) cluster(state year)
estimates store model14

** Baseline coefficient plot

coefplot (est1, mlabel("Non-Partisan Election Systems") mlabpos(.1)) (est2, mlabel("Partisan Election Systems") mlabpos(.1)) (est3,  mlabel("Merit Systems") mlabpos(.1)) (est4, mlabel("Governor Selection") mlabpos(.1)), nokey xline(0, lcolor(gs12)  lwidth(.1) lpattern(dash)) ci(90) ciopts( lpattern(shortdash_dot)) lwidth(3) xtitle("Effect of Polarization on Judge Decision Quality") ylabel("") keep(polar_start)

graph export "$output/figures/fig3.pdf", replace

